
		* Table A9
		* Balancing Test Using NELS 1988 with Interactions

		
		clear all
		set more off
	
		use "C:\Users\EAsker\Desktop\ABR\data\ABR_final_data"
		************************************************************************
		*********************** Drop 2nd and 3rd quartiles *********************
		************************************************************************
		* Keeping only the NELS 1988 for the balancing test
		keep if survey==1988
		
	egen student_id=group(stu_id survey)
	sort student_id survey wave mot_hs fat_hs white black hispanic female fam_inc
	duplicates drop student_id, force
	replace fam_inc=. if fam_inc==99|fam_inc==97|fam_inc==0
	gen ln_fam_inc=log(fam_inc)
		
		/* Create a reform indicator (SFR): if the reform year is not missing, 
		the state implemented a school finance reform. */
		gen SFR=0
		replace SFR=1 if CSFR_year_BJH~=.
		
		label var SFR "Reform"
		
		gen SFR_q1= SFR*qr80_1
		
		label var SFR_q1 "Reform*Quartile 1"
		
							
		foreach y of varlist mot_hs fat_hs ln_fam_inc not_white female {
		    
		reg `y'  SFR_q1 SFR qr80_1, cluster(fipst)
		
		outreg2 using Table_A9.xls, append ctitle(`y') bdec(4) nonotes  nocons  
		}
